<?php

namespace app\common\validate;

use think\Validate;

class Common extends Validate
{
	protected $rule = [
		'mobile' => ['require','regex' => '/^1[3|4|5|7|8][0-9]\d{8}$/i'],
	];
	protected $message = [
		'mobile.regex' => '手机号码格式错误',
		'mobile.unique' => '用户名已存在',
		'mobile.require' => '手机号码不能为空',
	];
	protected $scene = [
		'check_mobile' => ['mobile'],
	];
}